#ifndef _BSP_UART_H
#define _BSP_UART_H
#include <stdio.h>
#include <string.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "freertos/queue.h"
#include "driver/uart.h"
#include "esp_log.h"


#define EX_UART_NUM UART_NUM_0
#define PATTERN_CHR_NUM    (3)         /*!< Set the number of consecutive and identical characters received by receiver which defines a UART pattern*/

#define BUF_SIZE (100)
#define RD_BUF_SIZE (BUF_SIZE)



enum{
    UART_BLE_INFO_PROCESS_START = 0,    // 开始默认状态
    UART_BLE_INFO_PROCESS_1,            // 上位机发送"BLE"指令进入步骤1 
    UART_BLE_INFO_PROCESS_2,            // 进入待接收ble蓝牙名称步骤2
    UART_BLE_INFO_PROCESS_3,            // 步骤3蓝牙名称待确定
};



typedef struct
{
    uint8_t uart_ble_info_process;
    uint8_t uart_ble_name_buffer[19];
}uart_ble_info_t;












void my_uart0_init(void);
void uart_event_task(void *pvParameters);




#endif

